<html lang="en" xmlns:th="http://www.thymeleaf.org">
<head>
    <title th:text="后台管理"></title>
    <meta charset="UTF-8" />
    <meta name="renderer" content="webkit|ie-comp|ie-stand" />
    <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1" />
    <meta name="viewport" content="width=device-width, initial-scale=1.0, minimum-scale=1.0, maximum-scale=1.0, user-scalable=0"/>
    <meta http-equiv="Cache-Control" content="no-siteapp" />
    <link rel="stylesheet" th:href="@{/static/plugin/plugins/layui/css/layui.css}" media="all" />
    <link rel="stylesheet" th:href="@{/static/plugin/plugins/font-awesome/css/font-awesome.min.css}" media="all" />
    <link rel="stylesheet" th:href="@{/static/plugin/build/css/app.css}" media="all" />
    <link rel="stylesheet" th:href="@{/static/plugin/build/css/themes/default.css}" media="all" id="skin" kit-skin=""/>
    <style type="text/css">
        .layui-footer {background-color: #2F4056; }
        .layui-side-scroll { border-right: 3px solid #009688;}
    </style>
    <link id="layuicss-pluginbuildcssnprogresscss" rel="stylesheet"
          th:href="@{/static/plugin/build/css/nprogress.css}" media="all" />
    <link id="layuicss-layer" rel="stylesheet" media="all"
          th:href="@{/static/plugin/plugins/layui/css/modules/layer/default/layer.css(v=3.1.0)}" />
    <link id="layuicss-pluginbuildcssmessagecss" rel="stylesheet"
          th:href="@{/static/plugin/build/css/message.css}"  media="all" />
</head>
<body class="kit-theme">
<div class="layui-layout layui-layout-admin kit-layout-admin">
    <div class="layui-header">
        <div class="layui-logo">后台管理</div>
        <div class="layui-logo kit-logo-mobile"></div>
        <div class="layui-hide-xs">
        </div>
        <ul class="layui-nav layui-layout-right kit-nav">
            <li class="layui-nav-item">
                <a href="javascript:;">
                    <i class="layui-icon">&#xe63f;</i> 皮肤
                </a>
                <dl class="layui-nav-child skin">
                    <dd><a href="javascript:;" data-skin="default" style="color:#393D49;"><i class="layui-icon">&#xe658;</i> 默认</a></dd>
                    <dd><a href="javascript:;" data-skin="orange" style="color:#ff6700;"><i class="layui-icon">&#xe658;</i> 橘子橙</a></dd>
                    <dd><a href="javascript:;" data-skin="green" style="color:#00a65a;"><i class="layui-icon">&#xe658;</i> 春天绿</a></dd>
                    <dd><a href="javascript:;" data-skin="pink" style="color:#FA6086;"><i class="layui-icon">&#xe658;</i> 少女粉</a></dd>
                    <dd><a href="javascript:;" data-skin="blue.1" style="color:#00c0ef;"><i class="layui-icon">&#xe658;</i> 天空蓝</a></dd>
                    <dd><a href="javascript:;" data-skin="red" style="color:#dd4b39;"><i class="layui-icon">&#xe658;</i> 枫叶红</a></dd>
                </dl>
            </li>
            <li class="layui-nav-item">
                <a href="javascript:;">
                    <!--<#assign currentUser = Session["curentUser"]>-->
                    <!--<img src="/images/${currentUser.photo}" class="layui-nav-img"/>-->
                    <span th:text="${session.adminUser?.userName}"></span>
                </a>
                <dl class="layui-nav-child">
                    <dd><a href="javascript:;" kit-target="x" data-options="{url:'basic.html',icon:'&#xe658;',title:'基本资料',id:'966'}"><span>修改密码</span></a></dd>
                    <dd><a href="javascript:logout();">安全退出</a></dd>
                </dl>
            </li>
            <li class="layui-nav-item"><a href="javascript:logout();"><i class="fa fa-sign-out" aria-hidden="true"></i> 注销</a></li>
        </ul>
    </div>

    <div class="layui-side layui-nav-tree layui-bg-black kit-side">
        <div class="layui-side-scroll">
            <div class="kit-side-fold"><i class="fa fa-navicon" aria-hidden="true"></i></div>
            <ul class="layui-nav layui-nav-tree" lay-filter="kitNavbar" kit-navbar=""></ul>
        </div>
    </div>
    <div class="layui-body" id="container"></div>

    <div class="layui-footer">
        <!-- 底部固定区域 -->
        2018 © <a target="_blank" href="#">Workshop</a>
    </div>
</div>
<script type="text/javascript" th:src="@{/static/plugin/jquery/jquery-3.2.1.min.js}"></script>
<script th:src="@{/static/plugin/plugins/layui/layui.js}" type="text/javascript"></script>
<script type="text/javascript" th:src="@{/static/scripts/common/commom.js}"></script>
<script th:src="@{/static/plugin/tools/main.js}" type="text/javascript"></script>
<script th:inline="javascript">/*<![CDATA[*/
    $(function () {
        var html = "";
        var ctxPath = /*[[@{/}]]*/ '';
        ctxPath = ctxPath == '/' ? '' : ctxPath;
        var menus = [];
        var urlPermission = /*[[@{/system/permission/indexMenuTree}]]*/ "/system/permission/indexMenuTree";
        jQuery.ajax({url: urlPermission, async: false, type: 'post', dataType:"json",
            success: function (result) {
                menus = treeStructure.getTreeStructureNodes({items:result});
            }
        });
        for(var n = 0; n < menus.length; n++){
            var item = menus[n];
            html += "<li class=\"layui-nav-item" + (n == 0 ? ' layui-nav-itemed' : '') + "\">";
            html += "<a class=\"\" href=\"javascript:;\"><i aria-hidden=\"true\" class=\"layui-icon\">"+(item.icon?item.icon:'')+"</i><span>" + item.nameNode + "</span></a>";
            if(item.children && item.children.length > 0){
                html += "<dl class=\"layui-nav-child\">";
                for(var c in item.children){
                    var child = item.children[c];
                    html += "<dd><a href=\"javascript:;\" data-options=\"{url:'" + ctxPath + child.nodeUrl + "',title:'" + child.nameNode + "',id:'" + child.nodeId + "'}\"";
                    html += " kit-target=''><i class=\"layui-icon\">"+(child.icon?child.icon:'')+"</i><span>" + child.nameNode + "</span></a></dd>";
                }
                html += "</dl>";
            }
            html += "</li>";
        }
        html += "<span class=\"layui-nav-bar\" style=\"top: 22.5px; height: 0px; opacity: 0;\"></span>";
        $("ul.layui-nav-tree").html(html);
    });
    function  logout(){
        layer.confirm("您确定退出本系统?", {btn: ['确定', '取消'],title:"提示"}, function () {
            var url = /*[[@{/logout}]]*/ '/logout';
            url += "?" + Math.random();
            window.location.href = url;
        });
    }
/*]]>*/</script>
</body>
</html>